﻿
namespace Caffeine.Core
{
    public class ValueContainer<T> : ModelBase
    {
        private readonly ModelProperty<T> _valueProperty;

        public ValueContainer()
        {
            _valueProperty = RegisterProperty<T>("ValueProperty");
        }

        public T Value
        {
            get
            {
                return ValueProperty.Value;
            }
            set
            {
                ValueProperty.Value = value;
            }
        }

        public ModelProperty<T> ValueProperty
        {
            get
            {
                return _valueProperty;
            }
        }
    }
}
